package hn.cch.microservice.service_consumer_feign_config.feign.client;


import feign.Param;
import feign.RequestLine;
import hn.cch.microservice.configuration.FeignConfiguration;
import hn.cch.microservice.service_consumer_feign_config.entity.User;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "service-provider-user", configuration = FeignConfiguration.class)
public interface UserFeignClient {

    // @GetMapping(value = "/{id}")
    // public User user(@PathVariable(value = "id") Long id);

    @RequestLine(value = "GET /{id}")
    public User user(@Param(value = "id") Long id);

}